﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="CreateContent.ascx.cs" Inherits="Framework.Portal.Layouts.Admin.Components.Teenio.Author.CreateContent" %>
<table cellspacing="0" cellpadding="1" width="100%" align="center" border="0" class="content">
    <tr>
        <td class="postheader" width="70%" align="left" valign="top">
            <table align="center" width="100%" cellspacing="1" cellpadding="0" border="0" class="content">
                <tr>
                    <td class="header1" align="left" style="width: 388px">
                        <asp:Label ID="lblCommandName" runat="server"></asp:Label>
                    </td>
                </tr>
                <tr>
                    <td class="header2" height="18" style="width: 388px">
                        <asp:Label ID="lblUpdateStatus" runat="server" ForeColor="Blue" Font-Bold="True"></asp:Label>
                    </td>
                </tr>
                <tr>
                    <td class="postheader" style="width: 388px">
                        <NS:Label ID="Label1" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="CHOOSECATEGORY" /></td>
                </tr>
                <tr>
                    <td class="post" style="width: 388px">                        
                        <asp:DropDownList ID="dropZones" runat="server" Width="98%"></asp:DropDownList>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="dropZones" ErrorMessage="Chưa chọn mục lưu tin" Display="Dynamic">(*)</asp:RequiredFieldValidator>                        
                    </td>
                </tr> 
                 <tr>
                    <td class="post" style="width: 388px">
                    <asp:UpdatePanel ID="updatePanel" runat="server" UpdateMode="Conditional" RenderMode="Inline">
                        <contenttemplate>
                            <NS:Label ID="Label21" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="ARTICLETYPE" />: 
                            <asp:DropDownList ID="drpContentType" runat="server" Width="20%" DataValueField="key" DataTextField="value" OnSelectedIndexChanged="drpContentRank_SelectedIndexChanged" AutoPostBack="True"></asp:DropDownList>
                            <NS:Label ID="Label9" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="CHOOSEPERSPECTIVE" />: 
                            <asp:DropDownList ID="drpPerspective" runat="server" Width="30%">
                            </asp:DropDownList>
                        </contenttemplate>
                    </asp:UpdatePanel>                          
                    </td>
                </tr>
                <tr>
                    <td class="postheader" style="width: 388px">
                        <NS:Label ID="Label2" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="TITLE" /></td>
                </tr>
                <tr>
                    <td class="post" style="width: 388px">
                        <asp:TextBox ID="txtHeadline" runat="server" Width="98%" ></asp:TextBox>&nbsp;
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txtHeadline"
                            ErrorMessage="Chưa nhập tiêu đề" Display="Dynamic">(*)</asp:RequiredFieldValidator>
                    </td>
                </tr>
                <tr>
                    <td class="postheader" style="width: 388px">
                        <NS:Label ID="Label4" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="TEASER" /></td>
                </tr>
                <tr>
                    <td class="post" style="width: 388px">
                        <asp:TextBox ID="txtTeaser" runat="server" Width="100%" Rows="5" TextMode="MultiLine"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td class="postheader" style="width: 388px">
                        <NS:Label ID="Label5" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="CONTENT" /></td>
                </tr>
                <tr>
                    <td class="post" style="width: 388px">                        
                        <textarea id="txtRawContent" runat="server" rows="30" cols="80" style="width:100%;"></textarea>
                        <asp:HiddenField ID="hddContent" runat="server" />
                    </td>
                </tr>
            </table>
        </td>
        <td class="post" width="30%" align="left" valign="top">
            <asp:UpdatePanel ID="uppanelDistribution" runat="server" UpdateMode="Conditional"
                RenderMode="Inline">
                <contenttemplate>
                <table cellspacing="1" cellpadding="0" width="100%" align="center" class="content">             
            <tr>
                <td class="header2" colspan="2">Parameters (Article)</td>
            </tr>
            <tr>
                <td class="postheader" width="30%"><NS:Label ID="Label8" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="ARTICLERANK" /></td>
                <td class="post" width="70%">
                    <asp:DropDownList ID="drpContentRank" runat="server" Width="100%" DataValueField="key" DataTextField="value"></asp:DropDownList>
                </td>
            </tr>
            <tr>
                <td class="postheader"><NS:Label ID="lblNgaydangbai" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="PUBLISH" /></td>
                <td class="post">
                    <asp:TextBox ID="txtDatetime" runat="server" Width="100%"></asp:TextBox></td>
            </tr>
            <tr>
                <td class="postheader"><NS:Label ID="lblNgaygoxuong" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="UNPUBLISH" /></td>
                <td class="post">                    
                    <asp:TextBox ID="txtExprisedDate" runat="server" Width="100%"></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td class="postheader"><NS:Label ID="Label10" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="ALIAS" /></td>
                <td class="post">
                    <asp:Label ID="lblAlias" runat="server" Font-Bold="true"></asp:Label>
                </td>
            </tr>
            <tr>
                <td class="postheader"><NS:Label ID="Label11" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="SOURCE" /></td>
                <td class="post">
                    <asp:TextBox ID="txtSource" runat="server" Width="100%"></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td class="postheader"><NS:Label ID="Label12" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="COMMENT" /></td>
                <td class="post">
                    <asp:CheckBox ID="chkIsComment" runat="server" Checked="true"></asp:CheckBox>
                </td>
            </tr>            
            <tr>
                <td class="postheader"><%= Localization.GetText("PAY") %></td>
                <td class="post">
                    <asp:CheckBox ID="chkIsPay" runat="server" Checked="true"></asp:CheckBox>
                </td>
            </tr>
            <tr>
                <td class="header2" colspan="2">Avatars</td>
            </tr>
            <tr>
                <td class="postheader"><NS:Label ID="Label13" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="PREAVATAR" /></td>
                <td class="post">
                    <NS:FilePicker Width="90%" ID="txtSpecialAvatar" runat="server" FileType="jpg" PopupTitle="Up ảnh" PopupFilter="image"></NS:FilePicker>
                </td>
            </tr>
            <tr>
                <td class="postheader"><NS:Label ID="Label14" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="SIZE" /></td>
                <td class="post">
                    <asp:TextBox ID="txtSpecialAvatarwidth" runat="server" Width="35px"></asp:TextBox>
                    &nbsp;x&nbsp;
                    <asp:TextBox ID="txtSpecialAvatarHeight" runat="server" Width="35px"></asp:TextBox>&nbsp;(px)
                </td>
            </tr>
            <tr>
                <td class="postheader"><NS:Label ID="Label15" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="AVATAR" /></td>
                <td class="post">
                    <NS:FilePicker Width="90%" ID="txtAvatar" runat="server" FileType="jpg" PopupTitle="Up ảnh" PopupFilter="image"></NS:FilePicker>
                </td>
            </tr>
            <tr>
                <td class="postheader"><NS:Label ID="Label16" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="SIZE" /></td>
                <td class="post">
                    <asp:TextBox ID="txtAvatar2width" runat="server" Width="35px">173</asp:TextBox>
                    &nbsp;x&nbsp;
                    <asp:TextBox ID="txtAvatar2Height" runat="server" Width="35px">173</asp:TextBox>&nbsp;(px)
                </td>
            </tr>
            <tr>
                <td class="postheader"><NS:Label ID="Label17" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="DESCRIPTION" /></td>
                <td class="post">
                    <asp:TextBox ID="txtAvatarDes" runat="server" TextMode="MultiLine" Rows="3" Width="90%"></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td class="header2" colspan="2">Metadata Information</td>
            </tr>  
            <tr>
                <td class="postheader" valign="top"><NS:Label ID="Label18" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="KEYWORD" /></td>
                <td class="post">
                    <asp:TextBox ID="txtNoteBox" runat="server" TextMode="multiline" Rows="7" Width="90%"></asp:TextBox>
                </td>
            </tr>           
            <tr>
                <td class="postheader" valign="top"><NS:Label ID="Label19" runat="server" LocalizedPage="FORMCAPTION" LocalizedTag="CACHE" /></td>
                <td class="post">
                    <asp:CheckBox ID="chkCache" runat="server"></asp:CheckBox>
                </td>
            </tr>           
            </table>
            </contenttemplate>
            </asp:UpdatePanel>
        </td>
    </tr>
    <tr>
        <td class="postfooter" colspan="2" valign="middle" align="center">
            <NS:Button LocalizedPage="ACTION" LocalizedTag="PUBLISH" ID="cmdAdd" AccessKey="d" CssClass="pbutton" runat="server" Width="107px"
                ToolTip="Alt + D" OnClick="cmdAdd_Click" />
            <NS:Button LocalizedPage="ACTION" LocalizedTag="SAVE" ID="cmdSave" AccessKey="a" CssClass="pbutton" runat="server" Width="103px"
                ToolTip="Alt + A" Text="Lưu bài" OnClick="cmdSave_Click" />
            <NS:Button LocalizedPage="ACTION" LocalizedTag="RESET" ID="cmdHuy" AccessKey="e" CssClass="pbutton" runat="server" Width="110px"
                ToolTip="Alt + E" Text="Hủy" CausesValidation="False" OnClick="cmdHuy_Click" />
        </td>
    </tr>
</table>
<script type="text/javascript">    
    $(document).ready(function () {
        var initEditor = function () {
            $("#<%= txtRawContent.ClientID %>").sceditorBBCodePlugin({
                toolbar: "bold,italic,underline,|,left,center,right,justify,|,bulletlist,orderedlist,|,font,size,color,removeformat,|,image,emoticon,|,source",
                style: "/ClientScript/sceditor/css/jquery.sceditor.default.min.css"
            });
        };        
        initEditor();
    });
</script>